package com.umeng.soexample.mvp.model;

import com.umeng.lib_core.http.MResponseManager;
import com.umeng.lib_core.mvp.model.BaseModel;
import com.umeng.soexample.bean.SelUserEntity;
import com.umeng.soexample.bean.UpdateUserEntity;
import com.umeng.soexample.bean.UploadHeadEntity;
import com.umeng.soexample.mvp.contract.SelUserFragmentContract;
import com.umeng.soexample.network.API;

import java.util.List;

import javax.inject.Inject;

import io.reactivex.Observable;
import okhttp3.MultipartBody;

public class SelUserFragmentModel extends BaseModel implements SelUserFragmentContract.SelUserFragmentIModel {

    @Inject
    public SelUserFragmentModel() {}

    @Override
    public Observable<SelUserEntity> sel_user_request(String request) {
        return MResponseManager.obtainRetrofit(API.class).sel_user_request(request);
    }

    @Override
    public Observable<UpdateUserEntity> update_user__request(String request) {
        return MResponseManager.obtainRetrofit(API.class).update_user_request(request);
    }

    @Override
    public Observable<UploadHeadEntity> upload_head_request(List<MultipartBody.Part> request) {
        return MResponseManager.obtainRetrofit(API.class).upload_head_request(request);
    }

    @Override
    public void destroy() {

    }
}
